﻿<!DOCTYPE html>
<html>
<head>
    <title></title>
</head>
<body>
    <div style="color:#000" class="session-view-content">
      
        <table>
            <tr>
                <td>
                    <span class="form-label font-size-11">
                        {{$$$res('Mã nhóm')}}
                    </span>
                </td>
                <td>
                    <input type="text" class="k-textbox" ng-model="data.RoleID">
                </td>
            </tr>
            <tr>
                <td>
                    <span class="form-label font-size-11">
                        {{$$$res('Tên nhóm')}}
                    </span>
                </td>
                <td>
                    <input type="text" class="k-textbox" ng-model="data.RoleName">
                </td>
            </tr>
            <tr>
                <td>
                    <span class="form-label font-size-11">
                        {{$$$res('Ghi chú')}}
                    </span>
                </td>
                <td>
                    <input type="text" class="k-textbox" ng-model="data.Description">
                </td>
            </tr>
            <tr>
                <td>
                    <span class="form-label font-size-11">
                        {{$$$res('Ngày tạo')}}
                    </span>
                </td>
                <td>
                    <span class="font-size-11">{{$dateToString(data.CreatedOn,'dd-MM-yyyy hh:mm:ss')}}</span>
                    
                </td>
            </tr>
            <tr>
                <td>
                    <span class="form-label font-size-11">
                        {{$$$res('Tạo bởi')}}
                    </span>
                </td>
                <td>
                    <span class="font-size-11">
                    {{data.CreatedBy}}</span>

                </td>
            </tr>
            <tr>
                <td>
                    <span class="form-label font-size-11">
                        {{$$$res('Ngày điều chỉnh sau cùng')}}
                    </span>
                </td>
                <td>
                  
                    <span class="font-size-11">{{$dateToString(data.ModifiedOn,'dd-MM-yyyy hh:mm:ss')}}</span>
                </td>
            </tr>
            <tr>
                <td>
                    <span class="form-label font-size-11">
                        {{$$$res('Tạo bởi')}}
                    </span>
                </td>
                <td>
                    <span class="font-size-11">{{data.CreatedBy}}</span>

                </td>
            </tr>
            <tr>
                <td colspan="2">
                    <div template="tool_bar">
                        <input type="button" value="Cập nhật" class="k-button" ng-click="doUpdate();" />
                        <input type="button" value="Thêm" class="k-button" />
                        <input type="button" value="Xóa" class="k-button" />
                       
                        <input type="button" value="Bỏ qua" class="k-button" ng-click="$$$doClose();" />
                    </div>
                </td>
            </tr>
        </table>
    </div>
    <script>
        var scope = this;
        scope.data =  scope.$cloneData(scope.$parent.currentRole);
        scope.$apply();
        scope.$$$ready(function () {
            
           
        });
        scope.doUpdate = function () {
            scope.$parent.currentRole =scope.$cloneData(scope.data);
            scope.$parent.$apply();
            WS.$call("Roles/UpdateRoles", scope.data, function (res) {

            });
        }
    </script>
</body>
</html>